#!/usr/bin/env perl
#
# Copyright (c) 2012-2013 Jeffrey M. Squyres.  All rights reserved.
#
# $COPYRIGHT$
#
# $HEADER$
#

package RubySlippers::Util;

use strict;

use RubySlippers::Messages;


sub path_find {
    my $name = shift;

    Debug("Looking for $name");
    foreach my $d (split(':', $ENV{PATH})) {
        return "$d/$name"
            if (-x "$d/$name");
    }

    Debug("Did not find $name");
    return undef;
}

1;
